﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace LearnDrive
{
    public partial class frmPic : Form
    {
        public Image path;
        public frmPic(Image p)
        {
            InitializeComponent();
            path = p;
            this.Width = path.Width + 20;
            this.Height = path.Height + 50;
        }

        private void frmPic_Load(object sender, EventArgs e)
        {
            this.TopMost = true;
           
            pictureBox1.Image = path;
            this.StartPosition = FormStartPosition.CenterScreen;
        }

        private void pictureBox1_DoubleClick(object sender, EventArgs e)
        {
            this.Close();
        }
    }
}
